<admintpl file="header" />
</head>
<body>
<div class="wrap">
    <ul class="nav nav-tabs">
        <li class="active"><a>订单管理</a></li>
    </ul>
    <form class="well form-search" method="post" action="{:U('Dataanalysis/dispatch')}">
        工号：<input type="text" name="formget[job_number]" style="width: 100px;" value="{$formget.job_number}">
        跑客姓名：<input type="text" name="formget[dispatch_name]" style="width: 100px;" value="{$formget.dispatch_name}" placeholder="请输入关键字...">
        下单时间：
        <input type="text" name="formget[start_time]" class="js-date" value="{$formget.start_time|default=''}" style="width: 90px;" autocomplete="off">-
        <input type="text" class="js-date" name="formget[end_time]" value="{$formget.end_time}" style="width: 90px;" autocomplete="off"> &nbsp; &nbsp;
        &nbsp;&nbsp;<br>
        订单类型：
        <select class="select_2" name="formget[order_type]"  style="width: 80px;" >
            <option value='-1' {$formget[order_type]==-1?selected:''}>全部</option>
            <option value='1'{$formget[order_type]==1?selected:''}>取送订单</option>
            <option value='2'{$formget[order_type]==2?selected:''}>代买订单</option>
            <option value='3'{$formget[order_type]==3?selected:''}>代排队订单</option>
        </select> &nbsp;&nbsp;
        订单状态：
        <select class="select_2" name="formget[status]"  style="width: 80px;" >
            <option value='-1'{$formget[status]==-1?selected:''}>全部</option>
            <option value='0'{$formget[status]==0?selected:''}>未付款</option>
            <option value='1'{$formget[status]==1?selected:''}>待分配</option>
            <option value='2'{$formget[status]==2?selected:''}>已分配</option>
            <option value='3'{$formget[status]==3?selected:''}>已到达</option>
            <option value='4'{$formget[status]==4?selected:''}>已拍照</option>
            <option value='5'{$formget[status]==5?selected:''}>已取件</option>
            <option value='6'{$formget[status]==6?selected:''}>已送达</option>
            <option value='7'{$formget[status]==7?selected:''}>已完成</option>
            <option value='9'{$formget[status]==9?selected:''}>已取消</option>
        </select> &nbsp;&nbsp;
        是否预约单：
        <select class="select_2" name="formget[is_reservation]"  style="width: 70px;" >
            <option value='-1' {$formget[is_reservation]==-1?selected:''}>全部</option>
            <option value='0' {$formget[is_reservation]==0?selected:''}>否</option>
            <option value='1' {$formget[is_reservation]==1?selected:''}>是</option>
        </select> &nbsp;&nbsp;
        是否有效：
        <select class="select_2" name="formget[is_valid]"  style="width: 70px;" >
            <option value='-1' {$formget[is_valid]==-1?selected:''}>全部</option>
            <option value='0' {$formget[is_valid]==0?selected:''}>否</option>
            <option value='1' {$formget[is_valid]==1?selected:''}>是</option>
        </select> &nbsp;&nbsp;
        <input type="submit" class="btn btn-primary" value="搜索" />
    </form>
    总数：{$total_count}单
    <form method="post" class="js-ajax-form">
        <!--        <div class="table-actions">
                    <button class="btn btn-primary btn-small js-ajax-submit" type="submit" data-action="{:U('Bdrunpeople/sign',array('sign'=>1))}" data-subcheck="true">签约</button>
                    <button class="btn btn-primary btn-small js-ajax-submit" type="submit" data-action="{:U('Bdrunpeople/cancelsign',array('unsign'=>1))}" data-subcheck="true">取消签约</button>
                    <button class="btn btn-primary btn-small js-ajax-submit" type="submit" data-action="{:U('Bdrunpeople/incubator',array('incubator'=>1))}" data-subcheck="true">领取保温箱</button>
                    <button class="btn btn-primary btn-small js-ajax-submit" type="submit" data-action="{:U('Bdrunpeople/freezee',array('freezee'=>1))}" data-subcheck="true" data-msg="您确定冻结账户吗？">冻结</button>
                    <button class="btn btn-primary btn-small js-ajax-submit" type="submit" data-action="{:U('Bdrunpeople/cancelfreezee',array('cancelfreezee'=>1))}" data-subcheck="true" data-msg="您确定启用账户吗？">启用</button>
                    <button class="btn btn-primary btn-small js-ajax-submit" type="submit" data-action="{:U('Bdrunpeople/cancelaudit',array('audit'=>1))}" data-subcheck="true">取消审核</button>
                </div>-->
        <table class="table table-hover table-bordered">
            <thead>
            <tr>
                <th align="center">序号</th>
                <th>用户电话</th>
                <th>订单号</th>
                <th>下单时间</th>
                <th>订单类型</th>
                <th>订单状态</th>
                <th>支付方式</th>
                <th>跑客姓名</th>
                <th>跑客手机</th>
                <th>订单金额</th>
                <th>实付金额</th>
                <th>验证码</th>
                <th>是否预约单</th>
                <th>是否指派单</th>
                <th align="center">{:L('ACTIONS')}</th>
            </tr>
            </thead>
            <tbody>
            <php>$order_types=array("1"=>'取送订单',"2"=>'代买订单',"3"=>'排队订单');
                $order_status=array("0"=>'未付款',"1"=>'待分配',"2"=>'已分配',"3"=>'已到达',"4"=>'已拍照',"5"=>"已取件","6"=>"已送达","7"=>"已完成","9"=>'已取消');
                $pay_methods=array("1"=>'支付宝','2'=>'微信',"3"=>'钱包');
                $is_appoints=array("0"=>'否','1'=>'是');
            </php>
            <foreach name="lists" item="vo" key="k">
                <tr>
                    <td align="center">{$k+1}</td>
                    <td>{$vo.user_id|getUserMobile}</td>
                    <td>{$vo.order_number}</td>
                    <td>{$vo.order_time}</td>
                    <td>{$order_types[$vo[order_type]]}</td>
                    <td>{$order_status[$vo[status]]}</td>
                    <td>{$pay_methods[$vo[pay_method]]}</td>
                    <!--       <td>{$dispatchs[$vo['dispatch_id']]['job_number']}</td>
                           <td>{$dispatchs[$vo['dispatch_id']]['dispatch_name']}</td>
                           <td>{$dispatchs[$vo['dispatch_id']]['mobile']}</td>-->
                    <td>{$vo.dispatch_name}</td>
                    <td>{$vo.mobile}</td>
                    <td>{$vo.order_amount}</td>
                    <td>{$vo.real_amount}</td>
                    <td>{$vo.get_vali_code}</td>
                    <td>{$is_appoints[$vo[is_reservation]]}</td>
                    <td>{$is_appoints[$vo[is_appoint]]}</td>
                    <td align="center">
                        <a href="{:U('order_show',array('id'=>empty($vo['order_id'])?'':$vo['order_id'],'formget'=>$formget))}">查看</a>
                    </td>
                </tr>
            </foreach>
            </tbody>
        </table>
        <if condition="empty($lists)">
            <div style="padding: 30px;text-align: center;color: #999999">
                <i class="fa fa-database" style="font-size: 38px"></i><br />
                暂无数据
            </div>
        </if>
        <div class="pagination">{$page}</div>
    </form>
</div>
<script src="__PUBLIC__/js/common.js"></script>
</body>
</html>